<!--
 * @Date: 2023-02-15 10:31:38
 * @LastEditTime: 2023-02-22 12:05:11
 * @FilePath: /hash-guess-game/src/components/rework/RadioBtn/RadioBtn.vue
 * 介绍:
-->
<script lang="ts" setup>
const props = defineProps<Props>();
interface Props {
  /**是否禁用 */
  disabled?: boolean;
  value: any;
}
</script>

<template>
  <VanRadio class="RadioBtn" :name="props.value" :disabled="props.disabled">
    <template #icon="{ checked }">
      <slot :checked="checked"></slot>
    </template>
  </VanRadio>
</template>

<style lang="less" scoped>
.RadioBtn {
  margin-right: initial;
  border-radius: 11rem;
  border: var(--C-T1) 1rem solid;
  height: auto !important;
  overflow: visible !important;
  padding: 0.45em;
  flex: 1;
  text-align: center;
  :deep(.van-radio__icon) {
    height: auto !important;
    flex: 1;
  }
}
[aria-checked="true"] {
  background: var(--C-M2);
}
</style>
